function isLocalPhone(text) {
  const pattern = /\d{3,4}-\d{8}/;
  return pattern.test(text);
}

console.log(isLocalPhone("010-12345678"));
console.log(isLocalPhone("0418-12345678"));
console.log(isLocalPhone("hello"));
console.log(isLocalPhone("18805020123"));
